<?php
//前台首页控制器
class IndexControl extends CommonControl{

    function index(){
        //p($_SESSION);die();
    	//分配轮播图
    	$lunbo=K('goods')->get_data(array('gid','gindex_img'),array('gattr like "首页轮播"'),'gsort ASC');
    	$this->assign('lunbo',$lunbo);

		//分配当日精选
    	$jingxuan=K('goods')->get_data(array('gid','gone_words','gindex_img'),array('gattr like "当日精选"'),'gsort ASC');
    	$this->assign('jingxuan',$jingxuan);

    	//分配热门推荐
    	$tuijian=K('goods')->get_data(array('gid','gone_words','gindex_img'),array('gattr like "热门推荐"'),'gsort ASC');
    	$this->assign('tuijian',$tuijian);

        //分配天天特价
        $tejia=K('goods')->get_data(array('gid','gone_words','gindex_img'),array('gattr like "天天特价"'),'gsort ASC');
        $this->assign('tejia',$tejia);

    	$this->display();
    }
}
?>